package cn.script;

import javafx.application.Application;
import javafx.fxml.FXMLLoader;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.stage.Stage;

import java.io.IOException;

public class AppStart extends Application {

    //
    public static void main(String[] args) {
        launch(AppStart.class, args);
    }

    @Override
    public void start(Stage stage) {
        FXMLLoader loader = new FXMLLoader(this.getClass().getResource("/fxml/app.fxml"));
        try {
            Parent root = loader.load();
            stage.setScene(new Scene(root));
            stage.show();
            stage.setOnCloseRequest((e) -> {
                System.exit(0);
            });
        } catch (IOException e) {
            e.printStackTrace();
        }

//        FXPlusApplication.start(AppStart.class);
    }
}
